<?php

/**
 * WeEngine System
 *
 * (c) We7Team 2021 <https://www.w7.cc>
 *
 * This is not a free software
 * Using it under the license terms
 * visited https://www.w7.cc for more details
 */

namespace W7\Addons\demo_tp_mini\Upgrade100;

use W7\Sdk\OpenCloud\Contracts\ModuleUpgradeInterface;

class Up implements ModuleUpgradeInterface
{
    public function database(): array
    {
        $sql[] = <<<SQL
CREATE TABLE IF NOT EXISTS`ims_demo_tags` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
SQL;
        return $sql;
    }

    public function script(): bool
    {
        return true;
    }
}
